<?php
/**
 * This file is part of webman.
 *
 * Licensed under The MIT License
 * For full copyright and license information, please see the MIT-LICENSE.txt
 * Redistributions of files must retain the above copyright notice.
 *
 * @author    walkor<walkor@workerman.net>
 * @copyright walkor<walkor@workerman.net>
 * @link      http://www.workerman.net/
 * @license   http://www.opensource.org/licenses/mit-license.php MIT License
 */

return [
    ''      => [
        \app\middleware\Poweredby::class,
    ],
    'h5'   => [
        \app\middleware\StatisticByH5::class, // 接口请求即时上报
        \app\middleware\LimitTraffic::class,//令牌桶限流
        \app\middleware\ActionHook::class,
    ],
    'web'   => [
        \app\middleware\StatisticByWeb::class, // 接口请求即时上报
        \app\middleware\LimitTraffic::class,//令牌桶限流
        \app\middleware\VerifySign::class,//签名验证
//        \app\middleware\StatisticSQLByWeb::class, // SQL监控即时上报
        \app\middleware\ActionHook::class,
        \app\middleware\BaseRequest::class,
    ],
    'api'   => [
//        \app\middleware\StatisticByApp::class, // 接口请求即时上报
        \app\middleware\LimitTraffic::class,//令牌桶限流
//        \app\middleware\VerifySign::class,//签名验证
//        \app\middleware\StatisticSQLByApp::class, // SQL监控即时上报
        \app\middleware\ApiRoute::class,
        \app\middleware\ApiBaseRequest::class,
        \app\middleware\ActionHook::class,
    ],
    'admin' => [
        \app\middleware\StatisticByAdmin::class, // 接口请求即时上报
        \app\middleware\LimitTraffic::class,//令牌桶限流
//        \app\middleware\StatisticSQLByAdmin::class, // SQL监控即时上报
        \app\middleware\ApiRoute::class,
        \app\middleware\ApiBaseRequest::class,
        \app\middleware\ActionHook::class,
        plugin\admin\api\Middleware::class
    ],
];